var e = getApp(), o = e.api,
  is_loading_more = !1, is_no_more = !1;

Page({
  data: {
  },
  onLoad: function (o) {
    var user_id=o.user_id;
    var coupon_id=o.coupon_id;
    this.loadData(user_id, coupon_id);
  },
  onReady: function () {
   // e.pageOnReady(this);
  },
  onShow: function (ops) {
    //e.pageOnShow(this);
  },
  loadData: function (user_id,coupon_id) {
    console.log(user_id, coupon_id,777)
    var n = this;
    var t = getApp().getUser();
   
    wx.showLoading({
      title: "加载中"
    }),
  
      e.request({
        url: o.order.member_orderdetailc,
        method: "post",
        data: {
          id: coupon_id,
          userid: user_id,
        },
        success: function (e) {
          console.log(222, e);
          if (0 == e.code) {
            wx.hideLoading();
            n.setData({
              user_coupon: e
            })
          } else wx.showToast({
            title: "网络错误",
            image: "/images/icon-warning.png"
          });
        }
      });
    
  },
  hideModal: function () {
    this.setData({
      showModel: !1
    });
  },
  onHide: function () {
    e.pageOnHide(this);
  },
  onUnload: function () {
    e.pageOnUnload(this);
  },
  onPullDownRefresh: function () { },
  onReachBottom: function () { },
  onShareAppMessage: function () { }
});